{% extends 'base.html' %}
{% load i18n %}
{% load comments %}

{% block content %}
	<div class="single-post">
		<p class="pubdate">{{post.pub_date|date:"Y-m-d"}}</p>
		{{post.text|safe}}
		<p><a href="#createcomment">{% trans "Comment" %}</a></p>
	</div>
	<hr>
	<div class="comments">
		<h2>{% trans "Comments" %}</h2>
		{% get_comment_list for post as comment_list %}
		{% include "comments/list.html" %}
		<hr>
		<a name="createcomment"></a>
		<h2 id="comment">{% trans "Add comment" %}</h2>
		{% include "comments/errors.html" %}
		<form action="{{ post.get_absolute_url }}#error" method="POST">
			{% include "comments/page_form.html" %}
		</form>
	</div>
{% endblock %}


{% block sidebar %}
{% if post.sidebar %}
<div class="examples">
	{{post.sidebar|safe}}
</div>
{% else %}
{% include "startpage_sidebar.html" %}
{% endif %}
{% endblock %}
